package com.example.myproject.pattern;

import com.example.myproject.util.FileUtil;
import com.example.myproject.util.PhoneNumberUtilTest;

import java.io.File;
import java.util.HashSet;
import java.util.List;
import java.util.Set;

/**
 * Created by xi on 2018/7/15.
 */
public class TestPhoneUtil {
    public static void main(String args[])
    {
        List<String> dataList = FileUtil.readTxt(new File("G:/testphone/phone.txt"));
        Set<String> set = new HashSet<String>();
        for(String s : dataList){
            set.add(s);
        }
        for(String phone :set){
            long start = System.currentTimeMillis();
            PhoneNumberUtilTest.test(phone);
            System.out.println("phone:"+phone+",cost time=="+(System.currentTimeMillis()-start)+",ms");
        }
    }
}
